package com.navi.loaddata.core.gpEntity;

import javax.persistence.Column;
import javax.persistence.Id;
import java.io.Serializable;

/**
 * Created by Jay on 2018/3/25.
 */
public class MParamDPK implements Serializable {
    private String shopName;
    private String paramCollection;
    private String paramName;

    @Column(name = "shop_name")
    @Id
    public String getShopName() {
        return shopName;
    }

    public void setShopName(String shopName) {
        this.shopName = shopName;
    }

    @Column(name = "param_collection")
    @Id
    public String getParamCollection() {
        return paramCollection;
    }

    public void setParamCollection(String paramCollection) {
        this.paramCollection = paramCollection;
    }

    @Column(name = "param_name")
    @Id
    public String getParamName() {
        return paramName;
    }

    public void setParamName(String paramName) {
        this.paramName = paramName;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        MParamDPK mParamDPK = (MParamDPK) o;

        if (shopName != null ? !shopName.equals(mParamDPK.shopName) : mParamDPK.shopName != null) return false;
        if (paramCollection != null ? !paramCollection.equals(mParamDPK.paramCollection) : mParamDPK.paramCollection != null)
            return false;
        if (paramName != null ? !paramName.equals(mParamDPK.paramName) : mParamDPK.paramName != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = shopName != null ? shopName.hashCode() : 0;
        result = 31 * result + (paramCollection != null ? paramCollection.hashCode() : 0);
        result = 31 * result + (paramName != null ? paramName.hashCode() : 0);
        return result;
    }
}
